<admintpl file="header" />
</head>
<body>
<div class="wrap js-check-wrap">
    <ul class="nav nav-tabs">
        <li class="active"><a href="javascript:;">订单管理</a></li>
    </ul>
    <form class="well form-search" method="post" action="{:U('Store/index')}" id="form1">
        关键字：
        <input type="text" name="keyword" style="width: 200px;" value="{$keyword|default=''}" placeholder="订单号/商品名称/商户名称/用户名/归属店铺">
        时间：
        <input type="text" name="start_time" class="js-datetime" value="{$start_time|default=''}" style="width: 120px;" autocomplete="off">-
        <input type="text" class="js-datetime" name="end_time" value="{$end_time|default=''}" style="width: 120px;" autocomplete="off">

        <input type="submit" class="btn btn-primary" value="搜索" onclick="return index()"/>
        <a class="btn btn-danger" href="{:U('Order/index')}">清空</a>
        <input type="submit" class="btn btn-success" value="导出excel" onclick="return excel()"/>
    </form>
    <table class="table table-hover table-bordered table-list">
        <thead>
        <tr>
            <th>用户名</th>
            <th>订单号</th>
            <th>商家名称</th>
            <th>商品名称</th>
            <th>商品单价</th>
            <th>商品税费</th>
            <th>规格</th>
            <th>折扣价</th>
            <th>订单折扣价</th>
            <th>合计金额</th>
            <th>订单状态</th>
            <th>下单时间</th>
            <th>归属店铺</th>
            <th>操作</th>
        </tr>
        </thead>
        <tbody>
        <volist name="order" id ="ord">
            <tr>
                <td>{$ord.buyer_name}</td>
                <td>{$ord.order_sn}</td>
                <td>{$ord.seller_name}</td>
                <td>{$ord.goods_name}</td>
                <td>{$ord.price}</td>
                <td>{$ord.tax_price}</td>
                <td>{$ord.specification}</td>
                <td>{$ord.discount}</td>
                <td>{$ord.order_amount}</td>
                <td>{$ord.goods_amount}</td>
                <td>{$ord.status_value}</td>
                <td>{$ord.add_time|date="Y-m-d H:i",###}</td>
                <td>{$ord.s_name}</td>
                <td>
                    <a class="btn btn-success" href="{:U('Order/excel',array('order_id'=>$ord['order_id']))}"/>导出Excel</a>
                </td>
            </tr>
        </volist>
        </tbody>
    </table>
    <div class="pagination">{$page}</div>
    </form>
</div>
<script src="__PUBLIC__/js/common.js"></script>
<script src="__PUBLIC__/layer/layer.js"></script>
</body>
<script type="text/javascript">
    $(".btn-close").click(function () {
        window.parent.$('.bg-model').hide();
    })
    function index(){
        $("#form1").attr('action',"{:U('Order/index')}");
        return true;
    }
    function excel(){
        $("#form1").attr('action',"{:U('Order/excel')}");
        return true;
    }
</script>

</html>
